package net.jxtz.jxtzos.impl.auth;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import net.jxtz.jxtzos.entity.auth.WechatUser;
import net.jxtz.jxtzos.entity.auth.dto.WechatUserDto;
import net.jxtz.jxtzos.mapper.auth.WechatUserMapper;
import net.jxtz.jxtzos.service.auth.WechatUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * @author a123
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class WechatUserServiceImpl extends ServiceImpl<WechatUserMapper, WechatUser> implements WechatUserService {
    @Override
    public WechatUserDto getWechatUserByUnionId(String unionId) {
        return wechatUserMapper.getWechatUserByUnionId(unionId);
    }

    private WechatUserMapper wechatUserMapper;

    @Autowired
    public void setWechatUserMapper(WechatUserMapper wechatUserMapper){
        this.wechatUserMapper = wechatUserMapper;
    }
}
